<template>
	<view class="container">
		<view class="jilu_list">
			<view class="index_qiang" v-for="(item,index) in dataList" :key="index">
				<view class="flex">
					<view class="left flex flex-align">
						<view class="one">￥</view>
						<view class="two">{{item.price}}</view>
						<view class="tree">
							<view class="wenzi">满{{item.full_price}}可用</view>
							<view class="wenzi">{{item.remark}}</view>
						</view>
					</view>
					<view class="right">
						<view class="">去使用</view>
					</view>
				</view>
				
			</view>
		</view>
		<view class="empty-box" v-if="dataList.length==0">
			<image src="/static/noCart.png" mode=""></image>
			<view>暂无数据</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				page:1,
				dataList:[],
				type:''
			}
		},
		onLoad(e) {
			this.type=e.type
			this.getList()
		},
		onReachBottom() {
			this.page++
			this.getList()
		},
		methods: {
			getList(){
				let that = this
				that.tui.request('api.auth.nutrition/couponList', "POST",{page:that.page}, false, false, true).then((res) => {
					that.dataList = that.dataList.concat(res.data.list)
				}).catch((res) => {})
			},
		}
	}
</script>

<style lang="scss">
	page{padding:30rpx 0 0;}
	.jilu_list{padding: 0 30rpx ;}
	.index_qiang{background: url('/static/home/index_yhq.png') no-repeat;background-size: 100% 100%;margin:0 0 20rpx;padding:40rpx 0 40rpx 40rpx;position: relative;
		.left{width: 450rpx;background: linear-gradient(to right, #61ae3d, #397824); /*设置渐变的方向从左到右 颜色从ff0000到ffff00*/
			  -webkit-background-clip: text;/*将设置的背景颜色限制在文字中*/
			  -webkit-text-fill-color: transparent;/*给文字设置成透明*/
			.one{font-size: 24rpx;padding-top: 20rpx;}
			.two{font-size: 74rpx;font-weight: bold;}
			.tree{
				.wenzi{font-size: 24rpx;padding-left: 10rpx;margin-bottom: 6rpx;}
			}
		}
		.right{width: 225rpx;padding:15rpx 0 0 70rpx ;position: absolute;top: 50rpx;right: 40rpx;
			view{width:170rpx;height: 48rpx;background: linear-gradient(to right,#fdc57a,#fda36f);border-radius: 48rpx;text-align: center;color: #fff;line-height: 48rpx;font-size: 24rpx;}
		}
		
	}
</style>